package com.aj.databases.entry;

import java.io.Serializable;
import java.util.Collection;

import com.j256.ormlite.field.DatabaseField;
import com.j256.ormlite.field.ForeignCollectionField;
import com.j256.ormlite.table.DatabaseTable;

@DatabaseTable(tableName = "home")
public class Home implements Serializable {
	private static final long serialVersionUID = -4977514414734224404L;
	public static final String ID = "home_id";
	public static final String FAMILY_ID = "familyId";

	@DatabaseField(generatedId = true, useGetSet = true, columnName = ID)
	private Integer id;

	@DatabaseField(useGetSet = true, columnName = FAMILY_ID)
	private String familyId;

	@ForeignCollectionField(eager = true)
	private Collection<Family> familyList;

	public Home() {

	}

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public Collection<Family> getFamilyList() {
		return familyList;
	}

	public void setFamilyList(Collection<Family> familyList) {
		this.familyList = familyList;
	}

	public String getFamilyId() {
		return familyId;
	}

	public void setFamilyId(String familyId) {
		this.familyId = familyId;
	}

}
